package com.example.eventdemo;

import lombok.extern.slf4j.Slf4j;
import org.springframework.context.event.EventListener;
import org.springframework.stereotype.Component;

/**
 * @author Cary
 * @date 2022/3/24
 * 事件绑定
 */
@Component
@Slf4j
public class SysLogListener {
    @EventListener
    public void saveSysLog(SysLogEvent event) {
        log.info("收到日志，执行操作，日志内容：{}", event);
    }
}